# Contributor: TBK <alpine@jjtc.eu>
# Maintainer: TBK <alpine@jjtc.eu>
pkgname=twiggy
pkgver=0.6.0
pkgrel=3
pkgdesc="Twiggy a code size profiler for Wasm"
url="https://github.com/rustwasm/twiggy"
arch="all !s390x !riscv64" # Limited by cargo
license="Apache-2.0"
makedepends="cargo cargo-auditable"
source="$pkgname-$pkgver.tar.gz::https://github.com/rustwasm/twiggy/archive/$pkgver.tar.gz"


build() {
	cargo auditable build --release --locked
}

check() {
	cargo test --release --locked
}

package() {
	install -Dm755 target/release/"$pkgname" "$pkgdir"/usr/bin/"$pkgname"
}

sha512sums="fd998c11652a3c5adf72cfb8ebe08a2be0c91ae8d8041a834a6d075f9844d18d4a1e663aebf3f18529397035fe4b3e7d8c331a9788e2e897d875667d07400352  twiggy-0.6.0.tar.gz"
